package javacafe.serviceimple;

import java.util.List;

import javacafe.dao.SeminarDAO;
import javacafe.daoimpl.SeminarDAOImple;
import javacafe.dto.event.SeminarDTO;

public class SeminarServiceImple implements SeminarDAO {
	private SeminarDAO seminarDAO;
	private static SeminarServiceImple seminarService;
	
	private SeminarServiceImple(){
		seminarDAO = new SeminarDAOImple();	
	}
	
	public static SeminarServiceImple getInstance(){
		if (seminarService==null) {
			seminarService=new SeminarServiceImple();
		}
		return seminarService;
	}
	

	public void setSeminarDAO(SeminarDAO seminarDAO) {
		this.seminarDAO = seminarDAO;
	}

	public SeminarDAO getSeminarDAO() {
		return seminarDAO;
	}

	@Override
	public boolean addSeminar(SeminarDTO dto) {
		// TODO Auto-generated method stub
		return seminarDAO.addSeminar(dto);
	}


	@Override
	public List<SeminarDTO> getAllSeminar() {
		// TODO Auto-generated method stub
		return seminarDAO.getAllSeminar();
	}


	@Override
	public SeminarDTO getSeminar(SeminarDTO dto) {
		// TODO Auto-generated method stub
		return seminarDAO.getSeminar(dto);
	}


	@Override
	public boolean updateSeminar(SeminarDTO dto) {
		// TODO Auto-generated method stub
		return seminarDAO.updateSeminar(dto);
	}

	@Override
	public boolean deleteSeminar(SeminarDTO dto) {
		// TODO Auto-generated method stub
		return seminarDAO.deleteSeminar(dto);
	}

	

}
